package com.woniu.microuserserver.service;


import com.github.pagehelper.PageInfo;
import com.woniu.microcommonsserver.entity.UserInfoEntity;
import com.woniu.microuserserver.bean.SearchQuery;
import com.woniu.microuserserver.bean.UserBean;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface UserService {
    //登录方法
    public UserBean login(UserBean userBean);
    //根据条件查询表格方法
    public PageInfo<UserInfoEntity> searchByquery(SearchQuery searchQuery);
    //新增用户
    public int addUser(UserInfoEntity userInfoEntity);
    //根据用户名查询用户
    public UserInfoEntity searchOneByname(@Param("l") String loginName);
    //修改用户信息
    public int changeUser(@Param("u") UserInfoEntity userInfoEntity);
    //删除一条用户
    public int delUser(@Param("l") String loginName);
    //禁用/开启一条用户
    public int stopUser(@Param("l") String loginName,@Param("s") String status);
    //重置密码
    public int resetpd(@Param("l") String loginName);
    //根据多个id查询员工信息
    public List<UserInfoEntity> searchbyids(int[] ids);
    //查询所有部门
    public List<String> searchdepname();
    //给廖健的
    public List<UserInfoEntity> searchfour();
    //根据uid查询rid
    public List<Integer> searchRidsByUid(int uid);
    //根据uid查询实体
    public UserInfoEntity searchByUid(int uid);
}
